package com.chen.pojo.entry;

import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

/**
 * @author chen
 * @version 1.0
 * @date 2025/8/15
 * user实体类
 */
@Data
@TableName("tb_user")
@Schema(description = "用户实体类")
public class User {

    @Schema(description = "用户ID")
    @TableId
    private Integer id;

    @Schema(description = "角色ID")
    @JsonSerialize(using = ToStringSerializer.class)
    private Integer roleId;

    @Schema(description = "用户名")
    private String userName;

    @Schema(description = "登录名")
    private String loginName;

    @Schema(description = "密码")
    private String password;

    @Schema(description = "密钥")
    private String secret;

    @Schema(description = "所属区域ID")
    private String regionId;

    @Schema(description = "所属区域名称")
    private String regionName;

    @Schema(description = "角色编号")
    private String roleCode;

    @Schema(description = "手机号")
    private String mobile;

    @Schema(description = "启用状态")
    private Boolean status;

    @Schema(description = "头像")
    private String image;
}